//
//  PayManager.h
//  BDD
//
//  Created by Eton on 2017/4/8.
//  Copyright © 2017年 APE. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "WXApi.h"
#import "PayParam.h"

@class PayParameterInfo;

/**
 支付结果类型
 */
typedef enum : NSUInteger {
    PayResultType_Success = 0,//成功
    PayResultType_Cancel,//取消
    PayResultType_NetError,//网络错误
    PayResultType_Failed,//失败
} PayResultType;



typedef void(^PayCompletionBlock)(PayResultType resultType, NSString * errorStr);

@interface PayManager : NSObject<WXApiDelegate>{
    PayCompletionBlock _completionBlock;
}

@property (nonatomic, strong) NSDictionary *resultDic;

+(instancetype) shareInstance;

#pragma mark - 调起支付

-(void) payWithPayPlatform:(PayPlatformType)type parameterInfo:(PayParameterInfo*)params callBackBlock:(PayCompletionBlock)completionBlock;



@end
